function companyTjIindex() {
    var _this = this;
    var page;
    _this.obj = null;

    _this.init = function (page_data) {
        page = page_data;
        _this.initTable();
    };

    _this.initTable = function () {
        var list_url = appPath + "/admin/integralForCompany/queryCompanyIntegralTjList";
        page.init("dept_integral_form", list_url, "deptIntegrallist", "dept_integral_page", 1, 10);
        page.goPage(1);
        page.list = function (dataList) {
            var len = dataList.length;
            _this.obj = dataList;
            var inner = "", item;
            // 组装数据
            for (var i = 0; i < len; i++) {
                item = dataList[i];
                inner += '<tr>';
                inner += '<td width="30">' + (i + 1) + '</td>';
                inner += '<td >' + item['companyName'] + '</td>';
                inner += '<td width="110">' + item['deptName'] + '</td>';
                inner += '<td width="110">' + item['yearIntegral'] + '</td>';
                inner += '<td width="80">' + item['deptUserCount'] + '</td>';
                inner += '<td width="80">' + item['integralRate'] + '</td>';
                inner += '</tr>';
            }
            return inner;
        }
    };
    
    _this.export = function () {
        window.location.href = appPath + '/admin/integralForCompany/excel_export?fileName=' + $("#companyName").val()+ $("#year").val() + '年度积分.xlsx&year=' + $("#year").val();
    }

}

var companyTjIindex = new companyTjIindex();